-- GENERATED SPELL FOR [Spirit of Kolk] --


function spell0_12240(pUnit, Event) --@Demoralizing Shout,Self--
pUnit:FullCastSpellOnTarget(16244,pUnit)
pUnit:RegisterEvent('Sorts_12240', 30276, 1)
end

function spell1_12240(pUnit, Event) --@Strike,n/a--
pUnit:FullCastSpellOnTarget(14516,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_12240', 605, 1)
end

function Sorts_12240(pUnit, Event)
local choix_sorts_12240 = math.random(0, 1)
if choix_sorts_12240 == 0 then
pUnit:RegisterEvent('spell0_12240', 1, 1)
end
if choix_sorts_12240 == 1 then
pUnit:RegisterEvent('spell1_12240', 1, 1)
end
end

function mob12240_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_12240', math.random(1500, 3000), 1)
end

function mob12240_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob12240_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob12240_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(12240, 1, 'mob12240_Action')
RegisterUnitEvent(12240, 2, 'mob12240_Leave')
RegisterUnitEvent(12240, 3, 'mob12240_Kill')
RegisterUnitEvent(12240, 4, 'mob12240_Die')
